import os

# 需要使用路径名来获取文件名，目录名，绝对路径等等
def demo_1():
    path = '/Users/kepler/Data/data.csv'
    basename = os.path.basename(path)
    dirname = os.path.dirname(path)
    joinname = os.path.join('tmp', 'data', basename)
    print('{}, {}, {}'.format(basename, dirname, joinname))

if __name__ == '__main__':
    demo_1()